<template>
  <div class="app-container">
    <!-- 头部 -->
    <nav-Bar/>
    <!-- 容器 -->
    <div class="layout-content" style="margin:46px 0 50px 0;">
      <keep-alive v-if="$route.meta.keepAlive">
        <router-view></router-view>
      </keep-alive>
      <router-view v-else></router-view>
    </div>
    <!-- 底部tabBar -->
    <div class="layout-footer">
      <TabBar :data="tabbars"  />
    </div>

  </div>
</template>

<script>
import TabBar from '@/components/TabBar'//底部组件
import navBar from '@/components/header'
export default {
  name: 'AppLayout',
  components: {
    TabBar,
    navBar
  },
  data() {
    return {
      tabbars: [
        {
          title: '首页',
          to: {
            name: 'Home'
          },
          icon: 'home-o'
        },
        {
          title: '关于我',
          to: {
            name: 'About'
          },
          icon: 'user-o'
        }
      ]
    }
  },
  mounted(){
    
  },
  methods: {
 
  }
}
</script>
